import request from '@/utils/request'

export default{
    getTeacherListPage(currentPage,pageSize,teacherQuery){
        return request({
            // url:'/eduservice/teacher/pageTeacherCondition/'+currentPage+'/'+pageSize,
            //使用飘号来引用变量
            url:`/eduservice/teacher/pageTeacherCondition/${currentPage}/${pageSize}`,
            method:'post',
            data:teacherQuery
        })
    },
    removeDataById(id){
        return request({
            url:`/eduservice/teacher/${id}`,
            method:'delete'
        })
    },
    save(teacher){
        return request({
            url:`/eduservice/teacher`,
            method:'post',
            data:teacher
        })
    },
    getById(id){//用于数据回显
        return request({
            url:`/eduservice/teacher/${id}`,//飘号
            method:'get'
        })
    },
    update(teacher){
        return request({
            url:'/eduservice/teacher',
            method:'put',
            data:teacher
        })
    }
}


